﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using System.Windows.Forms;
using System.Runtime.InteropServices;


namespace Tool
{
    static class Program
    {
        [DllImport("Engine")]
        public static extern bool RendererInit(Int32 hWnd);

        [DllImport("Engine")]
        public static extern void RendererRender();



        /// <summary>
        /// The main entry point for the application.
        /// </summary>
        [STAThread]
        static void Main()
        {
            Form1 form = new Form1();
            form.Show();

            if (RendererInit(form.panel1.Handle.ToInt32()))
            {
                while (form.Created)
                {
                    Application.DoEvents();
                    RendererRender();
                }
            }
        }
    }
}
